package com.meida.module.bbs.client.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.meida.common.mybatis.base.entity.AbstractEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.meida.common.mybatis.annotation.TableAlias;

/**
 * 帖子
 *
 * @author flyme
 * @date 2019-12-06
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("bbs_content")
@TableAlias("content")
@ApiModel(value="BbsContent对象", description="帖子")
public class BbsContent extends AbstractEntity {

private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "contentId", type = IdType.ID_WORKER)
    private Long contentId;

    @ApiModelProperty(value = "分类")
    private Long contentTypeId;

    @ApiModelProperty(value = "标题")
    private String title;

    @ApiModelProperty(value = "内容")
    private String content;

    @ApiModelProperty(value = "图片")
    private String coverImage;

    @ApiModelProperty(value = "状态")
    private Integer contentState;

    @ApiModelProperty(value = "置顶序号")
    private Integer topOrder;

    @ApiModelProperty(value = "评论数量")
    private Integer commentNum;

    @ApiModelProperty(value = "推荐是否")
    private Integer recommend;

    @ApiModelProperty(value = "发布人")
    @TableField(value = "userId",fill = FieldFill.INSERT)
    private Long userId;

}
